package com.ruoyi.baoming.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.baoming.mapper.VolunteerMajorMapper;
import com.ruoyi.baoming.domain.VolunteerMajor;
import com.ruoyi.baoming.service.IVolunteerMajorService;

/**
 * 志愿专业信息Service业务层处理
 * 
 * @author xiaosong
 * @date 2024-11-20
 */
@Service
public class VolunteerMajorServiceImpl implements IVolunteerMajorService 
{
    @Autowired
    private VolunteerMajorMapper volunteerMajorMapper;

    /**
     * 查询志愿专业信息
     * 
     * @param id 志愿专业信息主键
     * @return 志愿专业信息
     */
    @Override
    public VolunteerMajor selectVolunteerMajorById(Long id)
    {
        return volunteerMajorMapper.selectVolunteerMajorById(id);
    }

    /**
     * 查询志愿专业信息列表
     * 
     * @param volunteerMajor 志愿专业信息
     * @return 志愿专业信息
     */
    @Override
    public List<VolunteerMajor> selectVolunteerMajorList(VolunteerMajor volunteerMajor)
    {
        return volunteerMajorMapper.selectVolunteerMajorList(volunteerMajor);
    }

    /**
     * 新增志愿专业信息
     * 
     * @param volunteerMajor 志愿专业信息
     * @return 结果
     */
    @Override
    public int insertVolunteerMajor(VolunteerMajor volunteerMajor)
    {
        return volunteerMajorMapper.insertVolunteerMajor(volunteerMajor);
    }

    /**
     * 修改志愿专业信息
     * 
     * @param volunteerMajor 志愿专业信息
     * @return 结果
     */
    @Override
    public int updateVolunteerMajor(VolunteerMajor volunteerMajor)
    {
        return volunteerMajorMapper.updateVolunteerMajor(volunteerMajor);
    }

    /**
     * 批量删除志愿专业信息
     * 
     * @param ids 需要删除的志愿专业信息主键
     * @return 结果
     */
    @Override
    public int deleteVolunteerMajorByIds(Long[] ids)
    {
        return volunteerMajorMapper.deleteVolunteerMajorByIds(ids);
    }

    /**
     * 删除志愿专业信息信息
     * 
     * @param id 志愿专业信息主键
     * @return 结果
     */
    @Override
    public int deleteVolunteerMajorById(Long id)
    {
        return volunteerMajorMapper.deleteVolunteerMajorById(id);
    }
}
